package com.smart.service;


import com.smart.dao.UserDao;
import com.smart.domain.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * Created by Jack on 2015/1/2.
 */
@Service
public class UserService {
    @Autowired
    private UserDao userDao;

    public  boolean hasMatchUser(int id,String password){
        int matchCount = userDao.getMatchCount(id,password);
        return matchCount > 0;

    }
    public  User getUserInfo(int id){
         return userDao.getUser(id);
    }


}
